-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Improve file read truncation UX with tooltips and consistent line range notifications #3633
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
|
Hey @cannuri, It seems like something happened when you generated the Other than that this looks good to me. |
oops... ok done |
daniel-lxs
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @cannuri, Thank you for fixing the issue with the types file.
I left another suggestion to hopefully have this reviewed soon.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While I understand that the translation autoTruncateTooltip is now necessary on the webview, it seems like it's the only translation currently used from this file, we might want to clean this up and only leave the used translation.
If leaving a locale file with a single translation key is undesirable then it might be a good idea to move it to chat.json.
…s of maxReadFileLine setting
|
stale |
Description
This PR addresses several issues related to file reading functionality and improves the user experience when working with large files and line range notifications:
Closes #3351
Added tooltips for truncation messages:
tools.jsonfiles to the webview-ui directory for all supported languages, ensuring consistent translations across both components of the application.Enhanced readFileTool with improved auto-truncate handling:
wasAutoTruncatedflag was not being set correctly, leading to inconsistent UI behavior when files were truncated.wasAutoTruncatedflag to ensure it's only set when a file is actually truncated due to themaxReadFileLinesetting, not when the user explicitly requests a range of lines.Improved line range notifications:
maxReadFileLinesetting, leading to inconsistent UI feedback.maxReadFileLinesetting, making the UI more consistent and informative.Hidden truncation messages for explicit line range reads:
UI improvements:
settings,context, andthreshold), ensuring consistency across the UI and all supported languages.These changes collectively improve the user experience when working with file content in Roo, making the behavior more intuitive and the UI more informative, especially when dealing with large files or specific line ranges.
Test Procedure
Testing was performed by:
node scripts/find-missing-translations.js) to ensure all translations are completeType of Change
Pre-flight Checklist
npm test) and code is formatted and linted (npm run format && npm run lint)npm run changeset(required for user-facing changes)Screenshots
BEFORE:

AFTER:

Additional Notes
This PR highlights the importance of maintaining consistent translation namespaces across both the extension and webview components. For future development, we should consider adding an automated check to ensure translation namespaces remain synchronized between the two components to prevent similar issues.
The improvements to line range notifications and truncation handling make the file reading experience more intuitive and consistent for users, especially when working with large files or specific line ranges.
Important
Enhance file read UX with tooltips, consistent line range notifications, and updated translations.
ChatRow.tsxto guide users on adjusting file read settings.wasAutoTruncatedflag logic inreadFileTool()inreadFileTool.tsto ensure correct UI behavior.readFileTool()to always display line range notifications.readFileTool.ts.tools.jsonfor all supported languages inwebview-ui/src/i18n/locales/to support new tooltips and messages.ClineSayToolinExtensionMessage.tsto includewasAutoTruncatedproperty.This description was created by
for b93412b65587a71bfa4995e7b405f37aa91d7d1f. You can customize this summary. It will automatically update as commits are pushed.